/** 当路由表太长时，可以将其拆分为小模块 **/

import Layout from 'views/layout/layout'

const accountingRouter = {
  path: '/accounting',
  component: Layout,
  redirect: 'noredirect',
  name: 'accounting',
  meta: {
    title: 'accounting',
    icon: 'accounting',
    roles: ['demo']
  },
  children: [
    {
      path: 'accountManage',
      component: () => import('pages/accounting/accountManage/index'),
      redirect: 'noredirect',
      name: 'accountManage',
      meta: {
        title: 'accountManage'
      },
      children: [
        {
          path: 'accountHome',
          component: () => import('pages/accounting/accountManage/accountHome'),
          name: 'accountHome',
          meta: {
            title: 'accountHome'
          }
        },
        {
          path: 'accountInfo',
          component: () => import('pages/accounting/accountManage/accountInfo'),
          name: 'accountInfo',
          meta: {
            title: 'accountInfo'
          }
        },
        {
          path: 'rechargeRecord',
          component: () => import('pages/accounting/accountManage/rechargeRecord'),
          name: 'rechargeRecord',
          meta: {
            title: 'rechargeRecord'
          }
        },
        {
          path: 'getCashRecord',
          component: () => import('pages/accounting/accountManage/getCashRecord'),
          name: 'getCashRecord',
          meta: {
            title: 'getCashRecord'
          }
        }
      ]
    },
    {
      path: 'statement',
      component: () => import('pages/accounting/statement/index'),
      redirect: 'noredirect',
      name: 'statement',
      meta: {
        title: 'statement'
      },
      children: [
        {
          path: 'receiptDetails',
          component: () => import('pages/accounting/statement/receiptDetails'),
          name: 'receiptDetails',
          meta: {
            title: 'receiptDetails'
          }
        },
        {
          path: 'receiptDayCollect',
          component: () => import('pages/accounting/statement/receiptDayCollect'),
          name: 'receiptDayCollect',
          meta: {
            title: 'receiptDayCollect'
          }
        },
        {
          path: 'receiptMonthCollect',
          component: () => import('pages/accounting/statement/receiptMonthCollect'),
          name: 'receiptMonthCollect',
          meta: {
            title: 'receiptMonthCollect'
          }
        },
        {
          path: 'refundDetails',
          component: () => import('pages/accounting/statement/refundDetails'),
          name: 'refundDetails',
          meta: {
            title: 'refundDetails'
          }
        },
        {
          path: 'refundDayCollect',
          component: () => import('pages/accounting/statement/refundDayCollect'),
          name: 'refundDayCollect',
          meta: {
            title: 'refundDayCollect'
          }
        },
        {
          path: 'refundMonthCollect',
          component: () => import('pages/accounting/statement/refundMonthCollect'),
          name: 'refundMonthCollect',
          meta: {
            title: 'refundMonthCollect'
          }
        },
        {
          path: 'supplierFinanceDetails',
          component: () => import('pages/accounting/statement/supplierFinanceDetails'),
          name: 'supplierFinanceDetails',
          meta: {
            title: 'supplierFinanceDetails'
          }
        }
      ]
    }
  ]
}

export default accountingRouter